<?php
/*
*邮件发送类
	$from_email	发件人邮箱地址
	$to_email		收件人邮箱地址
	$subject 		邮件主题
	$content 		邮件正文内容
*/
function sendmail($from_email, $to_email, $subject, $content)
{
	$CI = & get_instance();
	$CI->load->library('email');

	//设置参数
	$config['protocol'] = 'smtp';
	// $config['mailpath'] = 'F:/wamp/www';
	$config['smtp_host'] = 'smtp.163.com';
	$config['smtp_user'] = 'yglhcm';
	$config['smtp_pass'] = 'yglh@123';
	$CI->email->initialize($config);

	$CI->email->from($from_email, '央广联合传媒');
	$CI->email->to($to_email);
	$CI->email->subject($subject);
	$CI->email->message($content);

	return $CI->email->send();

}